package com.calendar.api.model.dto;

import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;
import java.util.ArrayList;
import java.util.List;

@Data
@NoArgsConstructor
@AllArgsConstructor
public class TaskDTO {
    private Long id;

    @NotBlank(message = "标题不能为空")
    private String title;

    private String description;

    @NotNull(message = "截止日期不能为空")
    private String dueDate;
    
    // 添加截止时间字段，精确到分钟
    private String dueTime;

    private Integer priority;

    @NotBlank(message = "分类ID不能为空")
    private String categoryId;

    private boolean completed = false;

    private List<SubTaskDTO> subtasks = new ArrayList<>();
} 